package com.msw.axon.repository;

import com.msw.axon.model.Games;
import com.msw.axon.model.GamesVo;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;

import java.util.List;

/**
 * Created by minshiwu on 2017/4/16.
 */
public interface GamesRepo extends JpaRepository<Games, Long> {

    @Query("select g.name from Games g order by g.id")
    List<Games> findGames();

    @Query(nativeQuery = true, value = "select daoju,  name from t_game")
    List<Object[]> findGamesXX();

}
